package ru.pb.global.network.engine.core;

import ru.pb.global.network.engine.NioSession;
import ru.pb.global.network.engine.buffer.NioBuffer;

/**
 * @author: Felixx
 */
public interface Protocol
{

	/**
	 * Simple implemention of decode
	 * 
	 * @param session
	 * @param buf
	 * @return
	 */
	public NioBuffer decode(NioSession session, NioBuffer buf);

	/**
	 * Simple implementiom of encode
	 * 
	 * @param session
	 * @param buf
	 * @return
	 */
	public void encode(NioSession session, NioBuffer buf);
}
